package eip.chapter4.invalidmessage.impl;

import java.util.Arrays;
import java.util.List;

import eip.chapter4.invalidmessage.Hotel;
import eip.chapter4.invalidmessage.HotelSearchMessage;
import eip.chapter4.invalidmessage.HotelSearchService;

/**
 * This service returns a list of Hotels that match the 
 * search criteria. 
 * 
 * @author nl24167
 */
public class HotelSearchServiceImpl implements HotelSearchService {

	public List<Hotel> searchHotels(HotelSearchMessage msg) {
		System.out.println("In search hotel with request:" + msg);
		Hotel hotel = new Hotel("Amsterdam Royal Inn",
								"round the corner",
								"Amsterdam",
								"the Netherlands",
								"Keizersgracht",
								 1,
								"+31-6-12345678");
		return Arrays.asList(new Hotel[] {hotel});
	}
}
